<template>
  <div class="button">
    <div @click="submitClick">{{text}}</div>
  </div>
</template>

<script>
export default {
  props:["text"],
  methods:{
    submitClick(){
      /* 把点击事件发送给父组件 */
      this.$emit("submitClick")
    }
  }
};
</script>

<style lang="less" scoped>
.button {
  padding: 2.778vw 2.778vw;
  div {
    height: 12.5vw;
    background-color: skyblue;
    text-align: center;
    line-height: 12.5vw;
    border-radius: 6.25vw;
    color: white;
    font-size: 4.444vw;
  }
}
</style>
